/*
 * @Description: 流程分类 API
 * @Author: zhuoda
 * @Date: 2024-03-21
 * @LastEditTime: 2024-03-21
 * @LastEditors: zhuoda
 */
import {postRequest, getRequest, putRequest, deleteRequest} from '/@/lib/axios';

export const categoryApi = {
  // 查询流程分类列表 @author zhuoda
  listCategory: (param) => {
    return getRequest('/flowable/category/list', param);
  },

  queryCategory: (param) => {
    return postRequest("/flowable/category/query", param);
  },

  // 查询流程分类详细 @author zhuoda
  getCategory: (id) => {
    return getRequest(`/flowable/category/${id}`);
  },

  // 新增流程分类 @author zhuoda
  addCategory: (param) => {
    return postRequest('/flowable/category', param);
  },

  // 修改流程分类 @author zhuoda
  updateCategory: (param) => {
    return putRequest('/flowable/category', param);
  },

  // 删除流程分类 @author zhuoda
  deleteCategory: (id) => {
    return deleteRequest(`/flowable/category/${id}`);
  }
};
